import java.util.ArrayList;


public abstract class SchedulingAlgorithm {
	//when you create a scheulding algorithm, you need to give it a reference to a readyQueue.
	
	boolean idle;
	ArrayList<Process> readyQueueRef;
	
	
	public SchedulingAlgorithm()
	{

	}
	
	public void SetReadyQueue(ArrayList<Process> queue)
	{
		readyQueueRef = queue;
	}
	
	//override this method in all of the subclasses
	//calculate which process to run based on what is in the readyQueue (which is the same readyQueue as in the ossimulator)
	//once you know what process you should run based on the algorithm, call 		p.RunForOneTick(); on that process
	public abstract void RunAReadyProcessForTick();

	public int getSizeOfReadyQueue(){
		return readyQueueRef.size();
	}
	
	public boolean idleProc() {
		return idle;
	}
	
}
